package com.example.springbootweb.bean;

import com.example.springbootweb.interfaces.DoIt;

import java.lang.reflect.Method;



public enum MethodName implements DoIt {
    test{
        @Override
        public Object doit(Object proxyed, Method method, Object[] args) {
            Object o = null;
            try {
                System.out.println("前置增强");
                o = method.invoke(proxyed, args);
                System.out.println("后置增强");
            } catch (Exception e) {
            }
            return o;
        }
    },

    test2{
        @Override
        public Object doit(Object proxyed, Method method, Object[] args) {
            Object o = null;
            try {
                System.out.println("前置增强");
                o = method.invoke(proxyed, args);
                System.out.println("后置增强");
            } catch (Exception e) {
            }
            return o;
        }
    }
}
